import 'package:wanxiang_app/generated/json/base/json_field.dart';
import 'package:wanxiang_app/generated/json/game_list_entity.g.dart';
import 'dart:convert';

@JsonSerializable()
class GameListEntity {
	late int code;
	late String msg;
	late List<GameListData> data;

	GameListEntity();

	factory GameListEntity.fromJson(Map<String, dynamic> json) => $GameListEntityFromJson(json);

	Map<String, dynamic> toJson() => $GameListEntityToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class GameListData {
	late String id;
	late String backimg;
	late String type;
	late String name;
	late String code;

	GameListData();

	factory GameListData.fromJson(Map<String, dynamic> json) => $GameListDataFromJson(json);

	Map<String, dynamic> toJson() => $GameListDataToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}